import React from 'react';
import { Form, InputNumber, Modal, Row, Col, Checkbox } from 'antd';
import './AddModal.css';
const FormItem = Form.Item;
const layout = {
    labelCol: { span: 10 },
    // wrapperCol: { span: 12, offset: 2 },
};
export default (props) => {
    const [form] = Form.useForm();
    return (
        <Modal
            visible={props.visible}
            wrapClassName="add-modal"
            width={620}
        >
            <Form
                form={form}
                // layout="inline"
                {...layout}
                labelAlign="left"
            >
                <Row gutter={24}>
                    <Col span={11}>
                        <FormItem
                            label="报警频率"
                            name="aaa"
                        >
                            <InputNumber />
                        </FormItem>
                    </Col>
                    <Col span={12}>
                        <Row>
                            <Col span={18}>
                                <FormItem
                                    label="报警频率111"
                                    name="ddd"
                                    labelCol={24}
                                >
                                    <InputNumber style={{ marginLeft: '22px' }} />
                                </FormItem>
                            </Col>
                            <Col span={6}>
                                <FormItem
                                    label="启用"
                                    name="able"
                                    labelCol={1}
                                >
                                    <Checkbox />
                                </FormItem>
                            </Col>
                        </Row>
                    </Col>

                    <Col span={11}>
                        <FormItem
                            label="报警频率2222"
                            name="bbb"
                        >
                            <InputNumber />
                        </FormItem>
                    </Col>

                    <Col span={12}>
                        <FormItem
                            label="报警频率11100"
                            name="ccc"
                        >
                            <InputNumber style={{ width: '100%' }} />
                        </FormItem>
                    </Col>

                </Row>


            </Form>
        </Modal>
    )
};